In a communication network, data traffic over a certain link may exceed a service level agreement signed with a service provider, at this time, a bandwidth of other links in the communication network would be occupied by this link, thus resulting in that other links cannot gain normal bandwidth services. In this situation, in order to guarantee the normal running of the communication network, the restriction of data traffic over a link needs to be performed at the entrance of the communication network, so as to prevent the data traffic over a link from exceeding the bandwidth service signed in the service level agreement.
The token bucket is common data traffic restriction technology, where the token bucket is a storage pool inside a network device, and a token refers to a virtual information packet which fills the token bucket at a given rate. Put tokens into the token bucket according to the data traffic allocated to the link, and meanwhile, take tokens out of the token bucket according to the actual data traffic over the link. When there is no token in the token bucket, data cannot be sent to this link anymore. Normally, the network device configures a token bucket for each chip set of single board, if the rate of putting the tokens into the token bucket is greater than the actual data traffic, then tokens received after the token bucket is full will be discarded; if the rate of putting the tokens into the token bucket is less than the actual data traffic, then data cannot be sent anymore after the token bucket ran out of tokens. However, this token access mode cannot make full use of remnant data traffic of the other links in a link aggregation group interface.
In traditional methods for data traffic restriction, it is very hard to keep the actual distributing situation of data traffic over each member port of the link aggregation group interface in accordance with the entire CIR of the link aggregation group interface or the entire PIR (Peak Information Rate, Peak Information Rate) of the link aggregation group interface.